package com.enbatis.mybatisplugs.plugin;

import com.github.pagehelper.Page;
import lombok.Data;

import java.util.List;
@Data
public class Pages<T>  {
  private   Integer  current;
  private   Integer  pages;
  private   Integer  size;
  private   Long  total;
  private   List<T> records;


  public Pages(Page returnPage){
    this.current=returnPage.getPageNum();
    this.size=returnPage.getPageSize();
    this.total=returnPage.getTotal();
    this.pages=returnPage.getPages();
    this.records=returnPage.getResult();
  }
  public Pages(){
  }

}
